<html xmlns="http://www.w3.org/1999/xhtml" xmlns:c="http://java.sun.com/jstl/core"
    xmlns:f="http://java.sun.com/jsf/core" xmlns:h="http://java.sun.com/jsf/html" 
    xmlns:ui="http://java.sun.com/jsf/facelets" xmlns:t="http://myfaces.apache.org/tomahawk">

<f:view>
<f:loadBundle var="text" basename="#{basePage.bundleName}"/>
<head>
    <title>#{text['activeUsers.title']}</title>
    <meta name="heading" content="#{text['activeUsers.heading']}"/>
    <meta name="menu" content="AdminMenu"/>
</head>

<body id="activeUsers">
    
    <p>#{text['activeUsers.message']}</p>
    
    <h:form id="activeUsersForm">
	<div class="tests_background" style="width:440px;">
		<t:dataTable id="activeUsers" var="user" value="#{activeUserList.users}" 
			rows="10" 
			sortColumn="#{activeUserList.sortColumn}" sortAscending="#{activeUserList.ascending}" 
			headerClass="standardTable_Header" 
			styleClass="mainTable" style="width:432px;"
			rowClasses="rowA, rowB"
			sortable="true">
			<t:column width="135px">
				<f:facet name="header">
					<t:commandSortHeader columnName="username" arrow="true">
						<h:outputText value="#{text['activeUsers.userName']}" /> 
					</t:commandSortHeader>
				</f:facet>
				<h:outputText value="#{user.username}" />
			</t:column>
			<t:column>
				<f:facet name="header">
					<t:commandSortHeader columnName="fullName" arrow="true">
						<h:outputText value="#{text['activeUsers.fullName']}" />
					</t:commandSortHeader>
				</f:facet>
				<h:outputText value="#{user.fullName}" />
			</t:column>
			<t:column>
				<f:facet name="header">
					<t:commandSortHeader columnName="review" arrow="true">
						<h:outputText value=" " />
					</t:commandSortHeader>
				</f:facet>
				<h:panelGroup layout="block">
					<h:outputLink value="mailto:#{user.email}" rendered="#{not empty user.email}">
						<h:graphicImage style="padding-left: 10px;" alt="#{text['icon.email']}" 
							url="/images/iconEmail.gif" />
					</h:outputLink> 
				</h:panelGroup>
			</t:column>
		</t:dataTable>

		<ui:include src="/common/tableFooter.xhtml">
			<ui:param name="tableName" value="activeUsers"/> 
		</ui:include>
	</div>
	
	<span class="buttongroup">
		<h:commandButton value="#{text['button.done']}" action="mainMenu" immediate="true"
				id="cancel" styleClass="button_small" onclick="bCancel=true"/>
	</span>	
	</h:form>
</body>
</f:view>
</html>   
